<?php
namespace App\Strategies;

use App\Services\Core\Store\Qiniu\QiniuService;

/**
 * Class PushStrategy
 * @package App\Strategies
 * 推送 & 任务弹窗 策略层
 */
class PushStrategy extends AppStrategy
{
    /**
     * @param $push
     * @return array
     * 任务弹窗数据处理
     */
    public static function getPopup($push)
    {
        $pushArr = [];
        $pushArr['name'] = $push['name'];
        $pushArr['push_times'] = $push['push_times'];
        $pushArr['description'] = $push['description'];
        $pushArr['url'] = $push['url'];
        $pushArr['img'] = QiniuService::getImgs($push['img']);

        return $pushArr;
    }
}